{load_language_text section="create_account"}
{load_language_text section="checkout_payment" name="payment"}
{load_language_text section="buttons" name="button"}
{config_load file="$language/gm_lang_$language.conf" section="lightbox"}

<!-- CUSTOMER ACCOUNT -->
{if $LIGHTBOX == 'true'}<div id="lightbox_content" style="display:none">{/if}
<div class="account{if $LIGHTBOX == 'true'} lightbox_block{/if}">
	{if $CHECKOUT_STARTED}
		<div class="process_bar">
		<ul>
				<li><label><span>{$payment.text_shoppingcart}</span></label></li>
				<li class="active"><label><span>{$payment.text_yourdata}</span></label></li>
				<li><label><span>{$payment.text_shipandpay}</span></label></li>
				<li><label><span>{$payment.text_confirm}</span></label></li>
		</ul>
		</div>
	{/if}
	{if $LIGHTBOX == 'true'}
		<div style="position:relative;">
			<div class="lightbox_close"><a href="{$LIGHTBOX_CLOSE}" class="icon_lightbox_close" title="{$button.close}">&nbsp;</a></div>
		</div>
	{/if}
	<h1{if $CHECKOUT_STARTED} class="h1_checkout"{/if}>{$txt.heading_create_account}</h1>

	{$FORM_ACTION}
	<h2 class="underline"><img class="png-fix" src="{$tpl_path}img/icons/personal-data.png" alt="" />{$txt.title_personal}</h2>
	<fieldset>
		<table cellspacing="0" cellpadding="0" border="0">
			{if $INPUT_MALE}
			<tr class="form_highlight">
				<td class="col_0 form_highlight_left"><label>{$txt.text_gender}</label></td>
				<td class="col_1 form_highlight_right">
					<input type="radio" value="{$INPUT_MALE_VALUE}" name="{$INPUT_MALE_NAME}"{if $form_data.gender.m.checked == '1'} checked="checked"{/if} /> {$txt.text_male}
					<input type="radio" value="{$INPUT_FEMALE_VALUE}" name="{$INPUT_FEMALE_NAME}"{if $form_data.gender.f.checked == '1'} checked="checked"{/if} /> {$txt.text_female}
					{if $form_data.gender.required == '1'} * {/if}
					{if $error_gender}<span class="class_error_message">{$error_gender}</span>{/if}
				</td>
			</tr>
			{/if}
			<tr class="form_highlight">
				<td class="col_0 form_highlight_left"><label>{$txt.text_firstname}</label></td>
				<td class="col_1 form_highlight_right">
					<input type="text" name="{$INPUT_FIRSTNAME_NAME}" value="{$form_data.firstname.value}" class="input-text" />
					{if $form_data.firstname.required == '1'} * {/if}
					{if $error_first_name}<span class="class_error_message">{$error_first_name}</span>{/if}
				</td>
			</tr>
			<tr class="form_highlight">
				<td class="col_0 form_highlight_left"><label>{$txt.text_lastname}</label></td>
				<td class="col_1 form_highlight_right">
					<input type="text" name="{$INPUT_LASTNAME_NAME}" value="{$form_data.lastname.value}" class="input-text" />
					{if $form_data.lastname.required == '1'} * {/if}
					{if $error_last_name}<span class="class_error_message">{$error_last_name}</span>{/if}
				</td>
			</tr>
			{if $birthdate=='1'}
			<tr class="form_highlight">
				<td class="col_0 form_highlight_left"><label>{$txt.text_birthdate}</label></td>
				<td class="col_1 form_highlight_right">
					<input type="text" name="{$INPUT_DOB_NAME}" value="{$form_data.birthdate.value}" class="input-text" />
					{if $form_data.birthdate.required == '1'} * {/if}
					{if $error_birth_day}<span class="class_error_message">{$error_birth_day}</span>{/if}
				</td>
			</tr>
			{/if}
			<tr class="form_highlight">
				<td class="col_0 form_highlight_left"><label>{$txt.text_email}</label></td>
				<td class="col_1 form_highlight_right">
					<input type="text" name="{$INPUT_EMAIL_NAME}" value="{$form_data.email.value}" class="input-text" />
					{if $form_data.email.required == '1'} * {/if}
					{if $error_mail}<span class="class_error_message">{$error_mail}</span>{/if}
				</td>
			</tr>
			<tr class="form_highlight">
				<td class="col_0 form_highlight_left"><label>{$txt.text_email_confirm}</label></td>
				<td class="col_1 form_highlight_right">
					<input type="text" name="{$INPUT_EMAIL_CONFIRM_NAME}" value="{if !$error_mail}{$form_data.email_confirm.value}{/if}" class="input-text" />
					{if $form_data.email_confirm.required == '1'} * {/if}
					{if $error_mail}<span class="class_error_message">{$error_mail}</span>{/if}
				</td>
			</tr>
		</table>
	</fieldset>

	{if $company=='1'}
	<h2 class="underline"><img class="png-fix" src="{$tpl_path}img/icons/professional-data.png" alt="" />{$txt.title_company}</h2>
	<fieldset>
		<table cellspacing="0" cellpadding="0" border="0">
			<tr class="form_highlight">
				<td class="col_0 form_highlight_left"><label>{$txt.text_company}</label></td>
				<td class="col_1 form_highlight_right">
					<input type="text" name="{$INPUT_COMPANY_NAME}" value="{$form_data.company.value}" class="input-text" />
					{if $form_data.company.required == '1'} * {/if}
				</td>
			</tr>
			{if $vat=='1'}
			<tr class="form_highlight">
				<td class="col_0 form_highlight_left"><label>{$txt.text_ustid}</label></td>

				<td class="col_1 form_highlight_right">
					<input type="text" name="{$INPUT_VAT_NAME}" value="{$form_data.vat.value}" class="input-text" />
					{if $error_vat}<span class="class_error_message">{$error_vat}</span>{/if}
				</td>
			</tr>
			{/if}
		</table>
	</fieldset>
	{/if}
	
	<h2 class="underline"><img class="png-fix" src="{$tpl_path}img/icons/address.png" alt="" />{$txt.title_address}</h2>
	<fieldset>
		<table cellspacing="0" cellpadding="0" border="0">
			<tr class="form_highlight">
				<td class="col_0 form_highlight_left"><label>{$txt.text_street}</label></td>
				<td class="col_1 form_highlight_right">
					<input type="text" name="{$INPUT_STREET_NAME}" value="{$form_data.street_address.value}" class="input-text" />
					{if $form_data.street_address.required == '1'} * {/if}
					{if $error_street}<span class="class_error_message">{$error_street}</span>{/if}
				</td>
			</tr>
			{if $INPUT_SUBURB}
			<tr class="form_highlight">
				<td class="col_0 form_highlight_left"><label>{$txt.text_suburb}</label></td>
				<td class="col_1 form_highlight_right">
					{if $form_data.suburb.required == '1'} * {/if}
					<input type="text" name="{$INPUT_SUBURB_NAME}" value="{$form_data.suburb.value}" class="input-text" />
				</td>
			</tr>
			{/if}
			<tr class="form_highlight">
				<td class="col_0 form_highlight_left"><label>{$txt.text_code} / {$txt.text_city}</label></td>
				<td class="col_1 form_highlight_right">
					<input type="text" name="{$INPUT_CODE_NAME}" value="{$form_data.postcode.value}" class="input-text postal-code" /><input type="text" name="{$INPUT_CITY_NAME}" value="{$form_data.city.value}" class="input-text postal-code-city" />
					{if $form_data.city.required == '1' || $form_data.postcode.required == '1'} * {/if}
					{if $error_post_code}<span class="class_error_message">{$error_post_code}</span>{/if}
					{if $error_city}<span class="class_error_message">{$error_city}</span>{/if}
				</td>
			</tr>
			{if $INPUT_STATE}
			<tr class="form_highlight">
				<td class="col_0 form_highlight_left"><label>{$txt.text_state}</label></td>
				<td class="col_1 form_highlight_right">
					{if $form_data.state.type == 'selection'}
						<select class="input-select" name="{$form_data.state.name}">
							{foreach key=zones item=zone_data from=$zones_data}
								<option value="{$zone_data.id}"{if $zone_data.id == $form_data.state.value} selected="selected"{/if}>{$zone_data.text}</option>
							{/foreach}
						</select>
					{else}
						<input type="text" name="{$form_data.state.name}" value="{$form_data.state.value}" class="input-text" />
					{/if}
					{if $form_data.state.required == '1'} * {/if}
					{if $error_state}<span class="class_error_message">{$error_state}</span>{/if}
				</td>
			</tr>
			{/if}
			<tr class="form_highlight">
				<td class="col_0 form_highlight_left"><label>{$txt.text_country}</label></td>
				<td class="col_1 form_highlight_right">
					<select class="input-select" name="{$form_data.country.name}">
						{foreach key=countries item=country_data from=$countries_data}
							<option value="{$country_data.countries_id}"{if $country_data.countries_id == $form_data.country.value} selected="selected"{/if}>{$country_data.countries_name}</option>
						{/foreach}
					</select>
					{if $form_data.country.required == '1'} * {/if}
					{if $error_country}<span class="class_error_message">{$error_country}</span>{/if}
				</td>
			</tr>

		</table>
	</fieldset>

	{if $INPUT_TEL || $INPUT_FAX}
		<h2 class="underline"><img class="png-fix" src="{$tpl_path}img/icons/contact.png" alt="" />{$txt.title_contact}</h2>
		<fieldset>
			<table cellspacing="0" cellpadding="0" border="0">
				{if $INPUT_TEL}
					<tr class="form_highlight">
						<td class="col_0 form_highlight_left"><label>{$txt.text_tel}</label></td>
						<td class="col_1 form_highlight_right">
							<input type="text" name="{$INPUT_TEL_NAME}" value="{$form_data.telephone.value}" class="input-text" />
							{if $form_data.telephone.required == '1'} * {/if}
							{if $error_tel}<span class="class_error_message">{$error_tel}</span>{/if}
						</td>
					</tr>
				{/if}
				{if $INPUT_FAX}
					<tr class="form_highlight">
						<td class="col_0 form_highlight_left"><label>{$txt.text_fax}</label></td>
						<td class="col_1 form_highlight_right"><input type="text" name="{$INPUT_FAX_NAME}" value="{$form_data.fax.value}" class="input-text" /></td>
					</tr>
				{/if}
			</table>
		</fieldset>
	{/if}

	<h2 class="underline"><img class="png-fix" src="{$tpl_path}img/icons/password.png" alt="" />{$txt.title_password}</h2>
	<fieldset>
		<table cellspacing="0" cellpadding="0" border="0">
			<tr class="form_highlight">
				<td class="col_0 form_highlight_left"><label>{$txt.text_password}</label></td>
				<td class="col_1 form_highlight_right">
					<input type="password" name="{$INPUT_PASSWORD_NAME}" class="input-text" />
					{if $form_data.password.required == '1'} * {/if}
					{if $error_password}<span class="class_error_message">{$error_password}</span>{/if}
				</td>
			</tr>
			<tr class="form_highlight">
				<td class="col_0 form_highlight_left"><label>{$txt.text_confirmation}</label></td>
				<td class="col_1 form_highlight_right">
					<input type="password" name="{$INPUT_CONFIRMATION_NAME}" class="input-text" />
					{if $form_data.password.required == '1'} * {/if}
					{if $error_password2}<span class="class_error_message">{$error_password2}</span>{/if}
				</td>
			</tr>
		</table>
	</fieldset>

	{if $customer_upload == '1'}
	<div class="heading">
		<img src="{$tpl_path}icons/pwspeichern.gif"  alt="{$txt.title_password}" title="{$txt.title_password}" />
		<h2>
			{#title_customer_upload#}
		</h2>
	</div>

	{foreach name=aussen item=item from=$customer_upload_fields}

			<div style="clear:both" id="left_{$item.upload_fields_id}" class="cell_left">{$item.fields_name}</div>
			<div id="{$item.upload_fields_id}" class="cell_right">{$item.upload_field}
			{if $item.fields_error != ''}
				<span class="class_error_message">{$item.fields_error}</span>
			{/if}
			</div>
			<div style="clear:both" class="cell_left">&nbsp;</div>
			<div class="cell_right">{$item.upload_field_note}</div>
			<br />
	{/foreach}
	{/if}


	{if $show_privacy}
	<h2 class="underline"><img class="png-fix" src="{$tpl_path}img/icons/secrecy.png" alt="" />{$txt.title_privacy}</h2>
	<fieldset>
		<table cellspacing="0" cellpadding="0" border="0">
		<tr>
			<td class="col_0" style="width:100%">
			<span id="gm_privacy">
				{$PRIVACY_LINK}
			</span>
			</td>
		</tr>
		</table>
	</fieldset>
	{/if}

	<div class="back_button"><a href="{$BUTTON_BACK_LINK}" class="button_grey_big button_set_big"><span class="button-outer"><span class="button-inner">{$button.back}</span></span></a></div>
	<div class="send_button"><a href="{page_url}#" class="button_blue_big button_set_big action_submit"><span class="button-outer"><span class="button-inner">{$button.send}</span></span></a></div>

	{$FORM_END}
</div>
{if $LIGHTBOX == 'true'}</div>{/if}